package org.zhadoop.stream.cql.semanticanalyzer.parser.context;

import org.zhadoop.stream.cql.exception.SemanticAnalyzerException;
import org.zhadoop.stream.cql.semanticanalyzer.analyzecontext.expressiondesc.ExpressionDescribe;
import org.zhadoop.stream.cql.semanticanalyzer.parsecontextreplacer.ParseContextReplacer;
import org.zhadoop.stream.cql.semanticanalyzer.parsecontextwalker.ParseContextWalker;

/**
 * 逻辑表达式Not的语法分析结果
 * @author zwd
 *
 */
public class LogicExpressionNotContext extends BaseExpressionParseContext{

	private boolean isNot = false;
	
	//EqualRelationExpressionContext
	private BaseExpressionParseContext expression;
	
	@Override
	public String toString() {
		return isNot ? " NOT " + expression.toString() : expression.toString();
	}
	
	public boolean isNot() {
		return isNot;
	}

	public void setNot(boolean isNot) {
		this.isNot = isNot;
	}

	public BaseExpressionParseContext getExpression() {
		return expression;
	}

	public void setExpression(BaseExpressionParseContext expression) {
		this.expression = expression;
	}



	@Override
	public void walkChildAndReplace(ParseContextReplacer replacer) {
		
	}

	@Override
	protected ExpressionDescribe createExpressionDesc() throws SemanticAnalyzerException {
		// TODO Auto-generated method stub
		return null;
	}


	@Override
	protected void walkChild(ParseContextWalker walker) {
		// TODO Auto-generated method stub
		
	}

}
